Use this procedure to host instances of the Cobra Web Service on the Cobra Concurrency machine or on another machines.
When hosting to another machine, you will need to install the Cobra 8.3 Cumulative Update 08 or higher on that machine. You must update the Cobra.WebService.Host.exe.2.config or the Cobra.WebService.Host.exe.3.config file which are both shipped with Cobra. These files are located in your Cobra installation directory.
The default port for the first new Cobra Web Service instance is 8117. The default port for the second new instance is 8118.
To host Cobra Web Service instances:
-
Locate the
Cobra.WebService.Host.exe.2.config file that resides on the Cobra folder and open it using a text editor (such as Notepad).
-
Find the following line:
<add baseAddress="https://localhost:8117/CobraWebService"/>
-
Replace
localhost with the name of the machine, and replace
8117 if the port number conflicts with an external system.
For example:
<add baseAddress="https://MCOBPROCSER:8117/CobraWebService" />
Note: If this instance is not deployed on the Cobra Concurrency machine or is deployed on another machine, make sure that the firewall settings are allowed to communicate with the port defined here. Take note of the entire URL appended with /service. This will be defined in the
Cobra Web Service Gateway Configuration Tool. For example: https://COBWSHOST:8117/CobraWebService/service.
-
Find the following lines:
<appSettings>
<add key="ServiceName" value="Cobra Web Service 2"/>
<add key="ServiceDescription" value="The second Cobra Web Service instance."/>
</appSettings>
-
Replace
ServiceName and
ServiceDescription with a unique values.
For example:
<appSettings>
<add key="ServiceName" value="Cobra Web Service MPCI 8117"/>
<add key="ServiceDescription" value="CWS for Multi-Project Concurrency Integration 1"/>
<appSettings>
Note: To easily trace specific web service in the logs, Deltek recommends entering meaningful values for
ServiceName and
ServiceDescription (for example, defining the Cobra Web Service for the Multi-Project Concurrent Integration and the port number). If the machine you are hosting this Cobra Web Service instance is hosting or will host other Cobra Web Service instances,
ServiceName must be unique.
-
Save and close the configuration file.
-
Launch the Command Prompt and select
Run as administrator.
-
On the Administrator Command Prompt window, enter the following lines:
"<Cobra Folder Path>\Cobra.WebService.Host.exe" –install –configfile=<configfile>
For example:
"<Cobra Folder Path>\Cobra.WebService.Host.exe" –install –configfile=Cobra.WebService.Host.exe.2.config
The command deploys the host into the Windows services.
Note: The command creates a Windows Service using the local system account. If your Cobra .csv files are stored in a network share, you will need to configure the Windows Service Log On account to use a domain account.
-
Close the Administrator Command Prompt window.
-
Launch the Windows Services Manager (Services MMC).
-
Locate the Name that matches the
ServiceName
provided in the configuration file.
-
Right-click that Windows service and select
Properties.
-
On the Log On tab, specify the dedicated Windows Domain Account in the
This account field.
-
Close the Properties window.
-
Restart the Windows Services.
-
Check whether or not the host is running in the Windows Services by browsing the address from the configuration file in an internet browser.
For example: http://localhost:8117/CobraWebService.
If the host is running, the page that displays confirms that you have created a service and provides details on how to test the service. If a page does not display, the host is either not configured correctly, the port might be blocked by the Windows fire wall, or the service is not running in the Windows services.
Note: If you want to host another instance of the Cobra Web Service, locate the
Cobra.WebService.Host.exe.3.config file and perform similar steps. If you want to add more instances, create a copy of the application configuration file and perform similar steps. Make sure you provide different port numbers for these instances.